package com.yc.txx.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

/**
 * <p>
 * 车辆表
 * </p>
 *
 * @author 廖老师
 * @since 2023-04-30
 */
public class Car implements Serializable {

    private static final long serialVersionUID = 1L;

    List<Image> images;
    // 存放车辆未完成借出记录
    List<Lease> leases;

    public List<Lease> getLeases() {
        return leases;
    }

    public void setLeases(List<Lease> leases) {
        this.leases = leases;
    }

    public List<Image> getImages() {
        return images;
    }

    public void setImages(List<Image> images) {
        this.images = images;
    }

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 品牌
     */
    private String brand;

    /**
     * 型号
     */
    private String model;

    /**
     * 图片路径
     */
    private String image;

    /**
     * 车辆介绍
     */
    private String intro;

    /**
     * 租赁价格: 元/天
     */
    private BigDecimal price;

    /**
     * 星级评分: 1~5
     */
    private Integer stars;

    /**
     * 状态: 在库,出库,维修
     */
    private String state;

    /**
     * 购入时间
     */
    private LocalDateTime intime;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getBrand() {
        return brand;
    }

    public void setBrand(String brand) {
        this.brand = brand;
    }

    public String getModel() {
        return model;
    }

    public void setModel(String model) {
        this.model = model;
    }

    public String getImage() {
        return image;
    }

    public void setImage(String image) {
        this.image = image;
    }

    public String getIntro() {
        return intro;
    }

    public void setIntro(String intro) {
        this.intro = intro;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public Integer getStars() {
        return stars;
    }

    public void setStars(Integer stars) {
        this.stars = stars;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public LocalDateTime getIntime() {
        return intime;
    }

    public void setIntime(LocalDateTime intime) {
        this.intime = intime;
    }

    @Override
    public String toString() {
        return "Car{" +
        "id=" + id +
        ", brand=" + brand +
        ", model=" + model +
        ", image=" + image +
        ", intro=" + intro +
        ", price=" + price +
        ", stars=" + stars +
        ", state=" + state +
        ", intime=" + intime +
        "}";
    }
}
